Skip to content

Conversation

@addaleax
Copy link
Collaborator

Do not use unqualified shell.waitForExit() in cases where we do not validate the exit code or check that no errors are displayed in the output, just assuming that the shell exited successfully, but instead intentionally always validate that these conditions are true in the cases in which we expect them to be.

@addaleax addaleax changed the title chore(e2e-tests): consistently wait for successful exits of shell chore(e2e-tests): consistently wait for successful exits of shell MONGOSH-1943 Dec 12, 2024
@addaleax addaleax force-pushed the 1943-e2e branch 2 times, most recently from f11536f to 8359b73 Compare December 12, 2024 14:38
Do not use unqualified `shell.waitForExit()` in cases where we
do not validate the exit code or check that no errors are displayed
in the output, just assuming that the shell exited successfully,
but instead intentionally always validate that these conditions are
true in the cases in which we expect them to be.
Copy link
Collaborator

@nirinchev nirinchev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice restructuring - I like the more explicit helper names. The test failures seem legit though and we should fix them before merging.

@addaleax
Copy link
Collaborator Author

@nirinchev Yeah – #2298 and #2300 should address these. Part of the motivation for this change here is that, had we always used this "explicitly await success or failure", that issue would have been much more visible since it would have shown up as a consistent failure, not a flaky one 🙂

@addaleax addaleax merged commit 6942b5c into main Dec 16, 2024
147 of 152 checks passed
@addaleax addaleax deleted the 1943-e2e branch December 16, 2024 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants